Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add mix-ins to allow external styling of data-table-cell elements #147

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

depeele
Copy link

@depeele depeele commented Sep 17, 2016

This pull request adds mix-ins to allow external styling of data-table-cell elements, both normal cells and those within a header.

  • normal cells : --iron-data-table-cell
  • header cells : --iron-data-table-header-cell

The change is primarily to allow resetting the size of header-cell height enabling the use of elements within the header that exceed the hard-coded height.


This change is Reviewable

Copy link
Owner

@Saulis Saulis left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not sure these are needed, user should be able to style the elements just withdata-table-cell and data-table-cell[header] CSS selectors?

@Storyyeller
Copy link

I think this is necessary when using iron-data-table with shadow dom. Ordinary CSS selectors won't pierce the shadow dom, but CSS variables can.

@Saulis
Copy link
Owner

Saulis commented Dec 20, 2016

@Storyyeller <data-table-cell>, <data-table-row>, <data-table-checkbox> elements are being exposed in the light DOM of <iron-data-table> by design, so no shadow DOM piercing is required.

See example here: http://jsbin.com/fetibiy/edit?html,output

@Storyyeller
Copy link

Oh, I see what you mean. I think my problem was that we were using ::content in our selectors, but the cells are not actually inside a content tag.

@Storyyeller
Copy link

I got it working now. Thanks for the help and sorry for bothering you.

@Saulis
Copy link
Owner

Saulis commented Dec 20, 2016

No problem at all, glad you got it working! 👍🏻

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants